﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="TestObjectDataSourceMasterDetailForm.aspx.cs" Inherits="RSSReader.pageswithContent.tests.TestObjectDataSourceMasterDetailForm" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title></title>
</head>
<body>
    <form id="form1" runat="server">
    <div>
    
        <asp:ObjectDataSource ID="ObjectDataSource1" runat="server" 
            SelectMethod="getXMLArticles" 
            TypeName="RSSReader.classesCustom.DataHandler" 
            onobjectcreating="ObjectDataSource1_ObjectCreating"></asp:ObjectDataSource>
    
    </div>
    <asp:ObjectDataSource ID="ObjectDataSource2" runat="server" 
        SelectMethod="getXMLArticle" 
        TypeName="RSSReader.classesCustom.DataHandler" 
        onobjectcreating="ObjectDataSource2_ObjectCreating">
        <SelectParameters>
            <asp:ControlParameter ControlID="GridView1" DefaultValue="1" Name="id" 
                PropertyName="SelectedValue" Type="Int32" />
        </SelectParameters>
    </asp:ObjectDataSource>


    <asp:GridView ID="GridView1" runat="server" 
        AutoGenerateColumns="False" 
        DataKeyNames="ID"
        DataSourceID="ObjectDataSource1" 
        EnableModelValidation="True">
        <Columns>
            <asp:CommandField ShowSelectButton="True" />
            <asp:BoundField DataField="ID" HeaderText="ID" SortExpression="ID" />
            <asp:BoundField DataField="siteID" HeaderText="siteID" 
                SortExpression="siteID" />
            <asp:BoundField DataField="logo" HeaderText="logo" SortExpression="logo" />
            <asp:BoundField DataField="category" HeaderText="category" 
                SortExpression="category" />
            <asp:BoundField DataField="title" HeaderText="title" SortExpression="title" />
            <asp:BoundField DataField="pubdate" HeaderText="pubdate" 
                SortExpression="pubdate" />
            <asp:BoundField DataField="description" HeaderText="description" 
                SortExpression="description" />
            <asp:BoundField DataField="fullArticle" HeaderText="fullArticle" 
                SortExpression="fullArticle" />
            <asp:BoundField DataField="weblink" HeaderText="weblink" 
                SortExpression="weblink" />
        </Columns>
    </asp:GridView>
    <asp:FormView ID="FormView1" runat="server" DataSourceID="ObjectDataSource2" 
        EnableModelValidation="True">
        <EditItemTemplate>
            ID:
            <asp:TextBox ID="IDTextBox" runat="server" Text='<%# Bind("ID") %>' />
            <br />
            siteID:
            <asp:TextBox ID="siteIDTextBox" runat="server" Text='<%# Bind("siteID") %>' />
            <br />
            logo:
            <asp:TextBox ID="logoTextBox" runat="server" Text='<%# Bind("logo") %>' />
            <br />
            category:
            <asp:TextBox ID="categoryTextBox" runat="server" 
                Text='<%# Bind("category") %>' />
            <br />
            title:
            <asp:TextBox ID="titleTextBox" runat="server" Text='<%# Bind("title") %>' />
            <br />
            pubdate:
            <asp:TextBox ID="pubdateTextBox" runat="server" Text='<%# Bind("pubdate") %>' />
            <br />
            description:
            <asp:TextBox ID="descriptionTextBox" runat="server" 
                Text='<%# Bind("description") %>' />
            <br />
            fullArticle:
            <asp:TextBox ID="fullArticleTextBox" runat="server" 
                Text='<%# Bind("fullArticle") %>' />
            <br />
            weblink:
            <asp:TextBox ID="weblinkTextBox" runat="server" Text='<%# Bind("weblink") %>' />
            <br />
            <asp:LinkButton ID="UpdateButton" runat="server" CausesValidation="True" 
                CommandName="Update" Text="Update" />
            &nbsp;<asp:LinkButton ID="UpdateCancelButton" runat="server" 
                CausesValidation="False" CommandName="Cancel" Text="Cancel" />
        </EditItemTemplate>
        <InsertItemTemplate>
            ID:
            <asp:TextBox ID="IDTextBox" runat="server" Text='<%# Bind("ID") %>' />
            <br />
            siteID:
            <asp:TextBox ID="siteIDTextBox" runat="server" Text='<%# Bind("siteID") %>' />
            <br />
            logo:
            <asp:TextBox ID="logoTextBox" runat="server" Text='<%# Bind("logo") %>' />
            <br />
            category:
            <asp:TextBox ID="categoryTextBox" runat="server" 
                Text='<%# Bind("category") %>' />
            <br />
            title:
            <asp:TextBox ID="titleTextBox" runat="server" Text='<%# Bind("title") %>' />
            <br />
            pubdate:
            <asp:TextBox ID="pubdateTextBox" runat="server" Text='<%# Bind("pubdate") %>' />
            <br />
            description:
            <asp:TextBox ID="descriptionTextBox" runat="server" 
                Text='<%# Bind("description") %>' />
            <br />
            fullArticle:
            <asp:TextBox ID="fullArticleTextBox" runat="server" 
                Text='<%# Bind("fullArticle") %>' />
            <br />
            weblink:
            <asp:TextBox ID="weblinkTextBox" runat="server" Text='<%# Bind("weblink") %>' />
            <br />
            <asp:LinkButton ID="InsertButton" runat="server" CausesValidation="True" 
                CommandName="Insert" Text="Insert" />
            &nbsp;<asp:LinkButton ID="InsertCancelButton" runat="server" 
                CausesValidation="False" CommandName="Cancel" Text="Cancel" />
        </InsertItemTemplate>
        <ItemTemplate>
            ID:
            <asp:Label ID="IDLabel" runat="server" Text='<%# Bind("ID") %>' />
            <br />
            siteID:
            <asp:Label ID="siteIDLabel" runat="server" Text='<%# Bind("siteID") %>' />
            <br />
            logo:
            <asp:Label ID="logoLabel" runat="server" Text='<%# Bind("logo") %>' />
            <br />
            category:
            <asp:Label ID="categoryLabel" runat="server" Text='<%# Bind("category") %>' />
            <br />
            title:
            <asp:Label ID="titleLabel" runat="server" Text='<%# Bind("title") %>' />
            <br />
            pubdate:
            <asp:Label ID="pubdateLabel" runat="server" Text='<%# Bind("pubdate") %>' />
            <br />
            description:
            <asp:Label ID="descriptionLabel" runat="server" 
                Text='<%# Bind("description") %>' />
            <br />
            fullArticle:
            <asp:Label ID="fullArticleLabel" runat="server" 
                Text='<%# Bind("fullArticle") %>' />
            <br />
            weblink:
            <asp:Label ID="weblinkLabel" runat="server" Text='<%# Bind("weblink") %>' />
            <br />

        </ItemTemplate>
    </asp:FormView>
    </form>
</body>
</html>
